<%--

<!------------------------------------------------------------------------------
 - Copyright 2006 CORE Solutions Limited
 - All rights reserved.
 - PROPRIETARY AND CONFIDENTIAL INFORMATION.
 - Use is subject to license terms.
 -
 - FUNCTION ID      :   CODE
 - AUTHOR           :   Saint Peng
 - DATE CREATE      :   2006/01/05
 - DESCRIPTION      :   a HEADER TAB JSP file for the function, CODE
 -                  :
 -                  :
 -                  :
 -
 - MODIFICATION HISTORY:
 - DATE         AUTHOR          VERSION NO.         COMMENT
 - -----------  --------------  ------------------  -------------------
 - 2006/01/05   Saint Peng      1.0                 source is generated.
 -
 -
 -
------------------------------------------------------------------------------->

--%>
<%@ include file="/jsp/com/erp/app/common/jsp/directives_include.jsp"%>

<%@ page import="com.erp.app.setup.codeSetup.vo.CodeHdrVo"%>
<%@ page import="com.erp.app.setup.codeSetup.web.CodeMaintenanceAction"%>
<%@ page import="com.erp.app.setup.codeSetup.web.CodeMaintenanceForm"%>

<%@ include file="/jsp/com/erp/app/common/jsp/html_include.jsp"%>

<jsp:useBean id="codeMaintenanceForm" scope="session" type="com.erp.app.setup.codeSetup.web.CodeMaintenanceForm" />

<!-- MUST use the following example to mark fields as mandatory field inputs-->
<!--
<td class="grid_header" nowrap><span class="mandatory_label">
<bean:message key="label.general.mandatory.field"/>
...</span></td>
-->
<%
formReadOnly = false;
TableSchema ts = codeMaintenanceForm.getTs();
%>

<table class="table_short_header">

	<tr>
		<%
		webLabel = ts.getDisplayWebLabelWithColonByObjectId("LBL_HDR_REF_MASTER_CODE");
		colSize = String.valueOf(ts.getColSizeByObjectId("LBL_HDR_REF_MASTER_CODE"));
		displaySize = String.valueOf(ts.getDisplaySizeByObjectId("LBL_HDR_REF_MASTER_CODE"));
		%>
		<td class="col_label">
			<html:text useExtensions="true" uiType="label" name="codeMaintenanceForm" property="refMasterCode"/>
		</td>
		<td class="col_value" nowrap>
			<logic:equal name="codeMaintenanceForm" property="pageMode" value="<%=codeMaintenanceForm.PAGE_MODE_CREATE%>">
				<html:text property="refMasterCode" styleClass="textbox1" readonly="<%=formReadOnly%>" size="<%=colSize%>" maxlength="<%=displaySize%>" value="<%=CommonUtil.nullToString(codeMaintenanceForm.getRefMasterCode())%>"/>
			</logic:equal>
			<logic:notEqual name="codeMaintenanceForm" property="pageMode" value="<%=codeMaintenanceForm.PAGE_MODE_CREATE%>">
				<bean:write name="codeMaintenanceForm" property="refMasterCode" filter="true"/>
			</logic:notEqual>
		</td>
	</tr>
	<tr>
		<%
		webLabel = String.valueOf(ts.getDisplayWebLabelWithColonByObjectId("LBL_HDR_REF_DESC"));
		colSize = String.valueOf(ts.getColSizeByObjectId("LBL_HDR_REF_DESC"));
		displaySize = String.valueOf(ts.getDisplaySizeByObjectId("LBL_HDR_REF_DESC"));
		%>
		<td class="col_label">
			<html:text useExtensions="true" uiType="label" name="codeMaintenanceForm" property="refDesc"/>
		</td>
		<td class="col_value" nowrap>
			<%
			colSize = String.valueOf(ts.getColSizeByObjectId("LBL_HDR_REF_DESC"));
			displaySize = String.valueOf(ts.getDisplaySizeByObjectId("LBL_HDR_REF_DESC"));
			%>
			<html:text property="refDesc" styleClass="textbox1" readonly="<%=formReadOnly%>" size="<%=colSize%>" maxlength="<%=displaySize%>" value="<%=CommonUtil.nullToString(codeMaintenanceForm.getRefDesc())%>"/>
		</td>
	</tr>
	<tr>
		<%
		webLabel = String.valueOf(ts.getDisplayWebLabelWithColonByObjectId("LBL_HDR_CREATE_USER"));
		colSize = String.valueOf(ts.getColSizeByObjectId("LBL_HDR_CREATE_USER"));
		displaySize = String.valueOf(ts.getDisplaySizeByObjectId("LBL_HDR_CREATE_USER"));
		%>
		<td class="col_label">
			<html:text useExtensions="true" uiType="label" name="codeMaintenanceForm" property="createUser"/>
		</td>
		<td class="col_value" nowrap>
			<html:text useExtensions="true" uiType="combobox" visibility="displayOnly" showCode="false" name="codeMaintenanceForm" property="createUser"/>

		</td>
	</tr>

	<tr>
		<%
		webLabel = String.valueOf(ts.getDisplayWebLabelWithColonByObjectId("LBL_HDR_CREATE_DATE"));
		colSize = String.valueOf(ts.getColSizeByObjectId("LBL_HDR_CREATE_DATE"));
		displaySize = String.valueOf(ts.getDisplaySizeByObjectId("LBL_HDR_CREATE_DATE"));
		%>
		<td class="col_label">
			<html:text useExtensions="true" uiType="label" name="codeMaintenanceForm" property="createDate"/>
		</td>
		<td class="col_value" nowrap>
			<%=CommonUtil.dateToString(CommonUtil.stringToTimestamp(
            codeMaintenanceForm.getCreateDate()), ProjectConstants.OUTPUT_DATETIME_FORMAT)%>

		</td>
	</tr>
	<tr>
		<%
		webLabel = String.valueOf(ts.getDisplayWebLabelWithColonByObjectId("LBL_HDR_UPDATE_USER"));
		colSize = String.valueOf(ts.getColSizeByObjectId("LBL_HDR_UPDATE_USER"));
		displaySize = String.valueOf(ts.getDisplaySizeByObjectId("LBL_HDR_UPDATE_USER"));
		%>
		<td class="col_label">
			<html:text useExtensions="true" uiType="label" name="codeMaintenanceForm" property="updateUser"/>
		</td>
		<td class="col_value" nowrap>
			<html:text useExtensions="true" uiType="combobox" visibility="displayOnly" showCode="false" name="codeMaintenanceForm" property="updateUser"/>
		</td>
	</tr>
	<tr>
		<%
		webLabel = String.valueOf(ts.getDisplayWebLabelWithColonByObjectId("LBL_HDR_UPDATE_DATE"));
		colSize = String.valueOf(ts.getColSizeByObjectId("LBL_HDR_UPDATE_DATE"));
		displaySize = String.valueOf(ts.getDisplaySizeByObjectId("LBL_HDR_UPDATE_DATE"));
		%>
		<td class="col_label">
			<html:text useExtensions="true" uiType="label" name="codeMaintenanceForm" property="updateDate"/>
		</td>
		<td class="col_value" nowrap>
			<%=CommonUtil.dateToString(CommonUtil.stringToTimestamp(
            codeMaintenanceForm.getUpdateDate()), ProjectConstants.OUTPUT_DATETIME_FORMAT)%>
		</td>
	</tr>
</table>

